package com.swh.service.Impl;


import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.swh.dao.DemandDao;
import com.swh.dao.ExamineDao;
import com.swh.entity.Demand;
import com.swh.entity.Examine;
import com.swh.entity.QualificationCondition;
import com.swh.service.DemandService;
import com.swh.service.ExamineService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author: swh
 * @Description:
 * @Date: 2020/12/14 14:46
 * @Version: 1.0
 */
@Service
public class ExamineServiceImpl extends BaseServiceImpl<Examine> implements ExamineService {

    @Autowired
    public ExamineServiceImpl(ExamineDao examineDao) {
        super(examineDao);
    }

    @Autowired
    private ExamineDao examineDao;

    @Override
    public PageInfo<Examine> selectPage(int pageNum, int pageSize, QualificationCondition condition) {
        PageHelper.startPage(pageNum,pageSize);
        List<Examine> list = examineDao.selectPage((pageNum - 1) * pageSize, pageSize,condition);
        PageInfo<Examine> pageInfo = new PageInfo<>(list);
        return pageInfo;
    }
}
